package org.sdp.pearproject.dto.convert;

import org.sdp.pearproject.dao.domain.*;
import org.sdp.pearproject.dto.request.*;
import java.util.Date;

/**
 * @ClassName: ProjectForTaskMemberRequestConvert
 * @Description:
 * @Author: SDP
 * @Date: 2022-11-14
 * @Version: 1.0
 * Table: pear_project
 * Comment:
 * 项目表
 */
public class ProjectForTaskMemberRequestConvert extends BaseConvert {
    public static ProjectForTaskMember convert(ProjectForTaskMemberRequest request) throws Exception {
        ProjectForTaskMember daoRequest = new ProjectForTaskMember();
        copyProperties(request, daoRequest);

        daoRequest.setTaskCode(daoRequest.getTaskCode() == null ? null : daoRequest.getTaskCode().trim());
        daoRequest.setMemberCode(daoRequest.getMemberCode() == null ? null : daoRequest.getMemberCode().trim());
        daoRequest.setJoinTime(daoRequest.getJoinTime() == null ? null : daoRequest.getJoinTime().trim());
        daoRequest.setCode(daoRequest.getCode() == null ? null : daoRequest.getCode().trim());
        daoRequest.setMembarAccountCode(daoRequest.getMembarAccountCode() == null ? null : daoRequest.getMembarAccountCode().trim());
        daoRequest.setName(daoRequest.getName() == null ? null : daoRequest.getName().trim());
        daoRequest.setAvatar(daoRequest.getAvatar() == null ? null : daoRequest.getAvatar().trim());

        return daoRequest;
    }
}
